package cn;

import cn.laixueit.source.DataDictApp;
import cn.laixueit.source.po.TbDataDict;
import cn.laixueit.source.service.DataDictService;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;

import javax.annotation.Resource;
import java.util.Arrays;
import java.util.List;

/**
 * @author duxiang
 * @date 2024/3/8 16:32
 */
@RunWith(SpringRunner.class)
@SpringBootTest(classes = DataDictApp.class)
public class Demo {

    @Resource
    private DataDictService dataDictService;

    @Test
    public void t(){
        List<TbDataDict> list = dataDictService.list();

    }

    @Test
    public void t2(){

        TbDataDict dict = dataDictService.lambdaQuery().setEntity(TbDataDict.builder().id(1).build()).one();

    }

    @Test
    public void t3(){

        List<TbDataDict> andDetail = dataDictService.findDataDictAndDetail(null);
        System.out.println("andDetail = " + andDetail);

    }
}
